3.1.11 \(\int \cos ^4(c+d x) (A+C \sec ^2(c+d x)) \, dx\) [11]

Optimal. Leaf size=61 \[ \frac {1}{8} (3 A+4 C) x+\frac {(3 A+4 C) \cos (c+d x) \sin (c+d x)}{8 d}+\frac {A \cos ^3(c+d x) \sin (c+d x)}{4 d} \]

[Out]

1/8*(3*A+4*C)*x+1/8*(3*A+4*C)*cos(d*x+c)*sin(d*x+c)/d+1/4*A*cos(d*x+c)^3*sin(d*x+c)/d

________________________________________________________________________________________

Rubi [A]
time = 0.03, antiderivative size = 61, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {4130, 2715, 8} \begin {gather*} \frac {(3 A+4 C) \sin (c+d x) \cos (c+d x)}{8 d}+\frac {A \sin (c+d x) \cos ^3(c+d x)}{4 d}+\frac {1}{8} x (3 A+4 C) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Cos[c + d*x]^4*(A + C*Sec[c + d*x]^2),x]

[Out]

((3*A + 4*C)*x)/8 + ((3*A + 4*C)*Cos[c + d*x]*Sin[c + d*x])/(8*d) + (A*Cos[c + d*x]^3*Sin[c + d*x])/(4*d)

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 2715

Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d*x]*((b*Sin[c + d*x])^(n - 1)/(d*n))
, x] + Dist[b^2*((n - 1)/n), Int[(b*Sin[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && Integ
erQ[2*n]

Rule 4130

Int[(csc[(e_.) + (f_.)*(x_)]*(b_.))^(m_.)*(csc[(e_.) + (f_.)*(x_)]^2*(C_.) + (A_)), x_Symbol] :> Simp[A*Cot[e
+ f*x]*((b*Csc[e + f*x])^m/(f*m)), x] + Dist[(C*m + A*(m + 1))/(b^2*m), Int[(b*Csc[e + f*x])^(m + 2), x], x] /
; FreeQ[{b, e, f, A, C}, x] && NeQ[C*m + A*(m + 1), 0] && LeQ[m, -1]

Rubi steps

\begin {align*} \int \cos ^4(c+d x) \left (A+C \sec ^2(c+d x)\right ) \, dx &=\frac {A \cos ^3(c+d x) \sin (c+d x)}{4 d}+\frac {1}{4} (3 A+4 C) \int \cos ^2(c+d x) \, dx\\ &=\frac {(3 A+4 C) \cos (c+d x) \sin (c+d x)}{8 d}+\frac {A \cos ^3(c+d x) \sin (c+d x)}{4 d}+\frac {1}{8} (3 A+4 C) \int 1 \, dx\\ &=\frac {1}{8} (3 A+4 C) x+\frac {(3 A+4 C) \cos (c+d x) \sin (c+d x)}{8 d}+\frac {A \cos ^3(c+d x) \sin (c+d x)}{4 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.06, size = 45, normalized size = 0.74 \begin {gather*} \frac {4 (3 A+4 C) (c+d x)+8 (A+C) \sin (2 (c+d x))+A \sin (4 (c+d x))}{32 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Cos[c + d*x]^4*(A + C*Sec[c + d*x]^2),x]

[Out]

(4*(3*A + 4*C)*(c + d*x) + 8*(A + C)*Sin[2*(c + d*x)] + A*Sin[4*(c + d*x)])/(32*d)

________________________________________________________________________________________

Maple [A]
time = 0.46, size = 65, normalized size = 1.07

method result size
risch \(\frac {3 A x}{8}+\frac {C x}{2}+\frac {A \sin \left (4 d x +4 c \right )}{32 d}+\frac {A \sin \left (2 d x +2 c \right )}{4 d}+\frac {\sin \left (2 d x +2 c \right ) C}{4 d}\) \(55\)
derivativedivides \(\frac {A \left (\frac {\left (\cos ^{3}\left (d x +c \right )+\frac {3 \cos \left (d x +c \right )}{2}\right ) \sin \left (d x +c \right )}{4}+\frac {3 d x}{8}+\frac {3 c}{8}\right )+C \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )}{d}\) \(65\)
default \(\frac {A \left (\frac {\left (\cos ^{3}\left (d x +c \right )+\frac {3 \cos \left (d x +c \right )}{2}\right ) \sin \left (d x +c \right )}{4}+\frac {3 d x}{8}+\frac {3 c}{8}\right )+C \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )}{d}\) \(65\)
norman \(\frac {\left (-\frac {3 A}{8}-\frac {C}{2}\right ) x +\left (-\frac {9 A}{8}-\frac {3 C}{2}\right ) x \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (-\frac {3 A}{4}-C \right ) x \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (\frac {3 A}{4}+C \right ) x \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (\frac {3 A}{8}+\frac {C}{2}\right ) x \left (\tan ^{10}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (\frac {9 A}{8}+\frac {3 C}{2}\right ) x \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\frac {2 A \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {2 A \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {\left (3 A -4 C \right ) \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 d}-\frac {\left (5 A +4 C \right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{4 d}-\frac {\left (5 A +4 C \right ) \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4} \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}\) \(241\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(d*x+c)^4*(A+C*sec(d*x+c)^2),x,method=_RETURNVERBOSE)

[Out]

1/d*(A*(1/4*(cos(d*x+c)^3+3/2*cos(d*x+c))*sin(d*x+c)+3/8*d*x+3/8*c)+C*(1/2*cos(d*x+c)*sin(d*x+c)+1/2*d*x+1/2*c
))

________________________________________________________________________________________

Maxima [A]
time = 0.53, size = 73, normalized size = 1.20 \begin {gather*} \frac {{\left (d x + c\right )} {\left (3 \, A + 4 \, C\right )} + \frac {{\left (3 \, A + 4 \, C\right )} \tan \left (d x + c\right )^{3} + {\left (5 \, A + 4 \, C\right )} \tan \left (d x + c\right )}{\tan \left (d x + c\right )^{4} + 2 \, \tan \left (d x + c\right )^{2} + 1}}{8 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^4*(A+C*sec(d*x+c)^2),x, algorithm="maxima")

[Out]

1/8*((d*x + c)*(3*A + 4*C) + ((3*A + 4*C)*tan(d*x + c)^3 + (5*A + 4*C)*tan(d*x + c))/(tan(d*x + c)^4 + 2*tan(d
*x + c)^2 + 1))/d

________________________________________________________________________________________

Fricas [A]
time = 1.79, size = 49, normalized size = 0.80 \begin {gather*} \frac {{\left (3 \, A + 4 \, C\right )} d x + {\left (2 \, A \cos \left (d x + c\right )^{3} + {\left (3 \, A + 4 \, C\right )} \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{8 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^4*(A+C*sec(d*x+c)^2),x, algorithm="fricas")

[Out]

1/8*((3*A + 4*C)*d*x + (2*A*cos(d*x + c)^3 + (3*A + 4*C)*cos(d*x + c))*sin(d*x + c))/d

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \left (A + C \sec ^{2}{\left (c + d x \right )}\right ) \cos ^{4}{\left (c + d x \right )}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)**4*(A+C*sec(d*x+c)**2),x)

[Out]

Integral((A + C*sec(c + d*x)**2)*cos(c + d*x)**4, x)

________________________________________________________________________________________

Giac [A]
time = 0.42, size = 73, normalized size = 1.20 \begin {gather*} \frac {{\left (d x + c\right )} {\left (3 \, A + 4 \, C\right )} + \frac {3 \, A \tan \left (d x + c\right )^{3} + 4 \, C \tan \left (d x + c\right )^{3} + 5 \, A \tan \left (d x + c\right ) + 4 \, C \tan \left (d x + c\right )}{{\left (\tan \left (d x + c\right )^{2} + 1\right )}^{2}}}{8 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^4*(A+C*sec(d*x+c)^2),x, algorithm="giac")

[Out]

1/8*((d*x + c)*(3*A + 4*C) + (3*A*tan(d*x + c)^3 + 4*C*tan(d*x + c)^3 + 5*A*tan(d*x + c) + 4*C*tan(d*x + c))/(
tan(d*x + c)^2 + 1)^2)/d

________________________________________________________________________________________

Mupad [B]
time = 2.44, size = 67, normalized size = 1.10 \begin {gather*} x\,\left (\frac {3\,A}{8}+\frac {C}{2}\right )+\frac {\left (\frac {3\,A}{8}+\frac {C}{2}\right )\,{\mathrm {tan}\left (c+d\,x\right )}^3+\left (\frac {5\,A}{8}+\frac {C}{2}\right )\,\mathrm {tan}\left (c+d\,x\right )}{d\,\left ({\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+1\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(c + d*x)^4*(A + C/cos(c + d*x)^2),x)

[Out]

x*((3*A)/8 + C/2) + (tan(c + d*x)*((5*A)/8 + C/2) + tan(c + d*x)^3*((3*A)/8 + C/2))/(d*(2*tan(c + d*x)^2 + tan
(c + d*x)^4 + 1))

________________________________________________________________________________________